<%@page import="org.apache.commons.lang.StringUtils"%>
<%@page import="org.apache.commons.lang.time.DateFormatUtils"%>
<%@page import="org.springframework.util.CollectionUtils"%>
<%@page import="java.util.Collection"%>
<%@ include file="../common/common_include.jsp"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%
	List<TbAppAreas> list = (List<TbAppAreas>)request.getAttribute("list");
	AreaMapForm form = (AreaMapForm)request.getAttribute("command");
	String areaname = StringUtils.isNotBlank(form.getAreaname())?form.getAreaname():"";
	UserInfo user = (UserInfo)SecurityContextHolder.getContext().getAuthentication().getPrincipal();
	String siteid = user.getSiteId();
	
%>

<div class="userListWrap">    
    <table id="areaMapListTable" class="easyui-datagrid"  title="" >
        <thead>
    		<tr>
    		    <th data-options="field:'areaname',width:80">区域围栏</th>				
				<th data-options="field:'sitename',width:80">站点名称</th>
				<th data-options="field:'siteid',width:60">站点ID</th>				
    			<th data-options="field:'province',width:90">省份</th>
    			<th data-options="field:'city',width:95">城市</th>
    			<th data-options="field:'enterdate',width:130" >添加时间</th>
    			<th data-options="field:'checkdate',width:130" >更新时间</th>
    			<th data-options="field:'pro',width:120">操作</th>
    		</tr>
        </thead>
        <tbody>
        	<%
        		if(!CollectionUtils.isEmpty(list)){
        			for(TbAppAreas area:list){
        				%>
       					 <tr s="<%=area.getAreaid() %>">
       					 	<td><i s="<%=area.getAreaid() %>"></i><%=(null!=area.getAreaname())?area.getAreaname()+"":"" %></td>
       					 	<td><%=(null!=area.getSitename())?area.getSitename()+"":"" %></td>
       					 	<td><%=(null!=area.getSiteid())?area.getSiteid()+"":"" %></td>
       					 	<td><%=(null!=area.getProvince())?area.getProvince()+"":"" %></td>
       					 	<td><%=(null!=area.getCity())?area.getCity()+"":"" %></td>
       					 	<td><%=null!=area.getEnterdate()?DateFormatUtils.format(area.getEnterdate().getTime(), "yyyy-MM-dd HH:mm:ss"):"" %></td>
       					 	<td><%=null!=area.getCheckdate()?DateFormatUtils.format(area.getCheckdate().getTime(), "yyyy-MM-dd HH:mm:ss"):"" %></td>
				    			<td>
										<a class="inLink" href="javascript:XF.Area.editMapSite('<%=area.getAreaid()%>')"><span>编辑围栏地图</span></a>
				    			</td>
			    		</tr>
        				<%
        			}
        		}
        	%>
    	</tbody>
    </table>
    <div class="pagination paginationFixWidth">
		<monggoTag:pagination 
		href="areaMap_search"
		pageSize="<%=form.getPageSize()%>" 
		totalRecord="<%=form.getTotalRecord() %>" 
		currentPage="<%=form.getPageNum() %>">
		</monggoTag:pagination> 
	</div>
</div>
<script>
	$('#areaMapListTable').datagrid();  
	//XF.Notice.initList();
</script>





























